Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[PM-13706] Add repository + stored procedures for private key regeneration #4898

Open
wants to merge 8 commits into
base: main
Choose a base branch
from

Conversation

Thomas-Avery
Copy link
Contributor

🎟️ Tracking

https://bitwarden.atlassian.net/browse/PM-13706

📔 Objective

The purpose of this PR is to add the database stored procedure and repository layer for the private key regeneration project.

This initial phase will only target users not in organizations and without emergency access setup.
In future PRs, the database operations will expand to handle these cases.

📸 Screenshots

⏰ Reminders before review

  • Contributor guidelines followed
  • All formatters and local linters executed and passed
  • Written new unit and / or integration tests where applicable
  • Protected functional changes with optionality (feature flags)
  • Used internationalization (i18n) for all UI strings
  • CI builds passed
  • Communicated to DevOps any deployment requirements
  • Updated any necessary documentation (Confluence, contributing docs) or informed the documentation team

🦮 Reviewer guidelines

  • 👍 (:+1:) or similar for great changes
  • 📝 (:memo:) or ℹ️ (:information_source:) for notes or general info
  • ❓ (:question:) for questions
  • 🤔 (:thinking:) or 💭 (:thought_balloon:) for more open inquiry that's not quite a confirmed issue and could potentially benefit from discussion
  • 🎨 (:art:) for suggestions / improvements
  • ❌ (:x:) or ⚠️ (:warning:) for more significant problems or concerns needing attention
  • 🌱 (:seedling:) or ♻️ (:recycle:) for future improvements or indications of technical debt
  • ⛏ (:pick:) for minor or nitpick changes

@Thomas-Avery Thomas-Avery requested a review from a team October 15, 2024 22:07
@Thomas-Avery Thomas-Avery self-assigned this Oct 15, 2024
@Thomas-Avery Thomas-Avery changed the title [PM-13706] Add Repository + Stored Procedures for Private Key regeneration [PM-13706] Add repository + stored procedures for private key regeneration Oct 15, 2024
Copy link

codecov bot commented Oct 15, 2024

Codecov Report

Attention: Patch coverage is 2.43902% with 40 lines in your changes missing coverage. Please review.

Project coverage is 42.15%. Comparing base (724f2ee) to head (bcd4e88).

Files with missing lines Patch % Lines
...ement/Repositories/UserAsymmetricKeysRepository.cs 0.00% 19 Missing ⚠️
...ement/Repositories/UserAsymmetricKeysRepository.cs 0.00% 17 Missing ⚠️
...re/KeyManagement/Models/Data/UserAsymmetricKeys.cs 0.00% 3 Missing ⚠️
...ucture.Dapper/DapperServiceCollectionExtensions.cs 0.00% 1 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main    #4898      +/-   ##
==========================================
- Coverage   42.17%   42.15%   -0.03%     
==========================================
  Files        1377     1380       +3     
  Lines       64419    64460      +41     
  Branches     5915     5917       +2     
==========================================
+ Hits        27170    27171       +1     
- Misses      36026    36066      +40     
  Partials     1223     1223              

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

Copy link
Contributor

github-actions bot commented Oct 15, 2024

Logo
Checkmarx One – Scan Summary & Detailsae90bb91-92ce-4ee6-b956-4b3f126aa382

New Issues

Severity Issue Source File / Package Checkmarx Insight
MEDIUM Privacy_Violation /src/Core/Auth/Services/Implementations/AuthRequestService.cs: 213 Attack Vector

Fixed Issues

Severity Issue Source File / Package
MEDIUM CSRF /src/Billing/Controllers/RecoveryController.cs: 38
MEDIUM CSRF /src/Api/Vault/Controllers/CiphersController.cs: 107
MEDIUM CSRF /src/Api/Controllers/PushController.cs: 38
MEDIUM CSRF /src/Admin/AdminConsole/Controllers/OrganizationsController.cs: 351
MEDIUM CSRF /src/Billing/Controllers/StripeController.cs: 164
MEDIUM CSRF /src/Api/AdminConsole/Public/Controllers/MembersController.cs: 96
MEDIUM CSRF /src/Api/AdminConsole/Controllers/OrganizationUsersController.cs: 227
MEDIUM CSRF /src/Admin/AdminConsole/Controllers/OrganizationsController.cs: 351
MEDIUM CSRF /src/Api/Vault/Controllers/CiphersController.cs: 107
MEDIUM CSRF /src/Api/AdminConsole/Public/Controllers/PoliciesController.cs: 42
MEDIUM CSRF /src/Api/AdminConsole/Public/Controllers/PoliciesController.cs: 62
MEDIUM CSRF /src/Api/AdminConsole/Controllers/PoliciesController.cs: 58
MEDIUM CSRF /src/Api/AdminConsole/Controllers/PoliciesController.cs: 75
MEDIUM CSRF /src/Api/Controllers/PushController.cs: 38
MEDIUM CSRF /src/Api/Controllers/PushController.cs: 38
MEDIUM Privacy_Violation /src/Core/Auth/Services/Implementations/AuthRequestService.cs: 208
LOW Log_Forging /src/Api/Vault/Controllers/CiphersController.cs: 170

@Thomas-Avery Thomas-Avery marked this pull request as ready for review October 16, 2024 19:57
@Thomas-Avery Thomas-Avery requested a review from a team as a code owner October 16, 2024 19:57
mzieniukbw
mzieniukbw previously approved these changes Oct 17, 2024
Copy link
Contributor

@mzieniukbw mzieniukbw left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

Copy link
Contributor

@rkac-bw rkac-bw left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants